<!doctype html> 
<html> 
<head> 
  <meta charset="utf-8"/>
  <title>后台管理系统</title>
  <meta name="author" content="DeathGhost" />
  <link rel="stylesheet" type="text/css" href="css/style.css" />
  <!--[if lt IE 9]>
  <script src="js/html5.js"></script>
  <![endif]-->
  <style>
  ul li ul li{
    float: left;
  }
  </style>
<script src="js/jquery.js"></script>
<script src="js/jquery.mCustomScrollbar.concat.min.js"></script>
<script>
  (function($){
    $(window).load(function(){
      
      $("a[rel='load-content']").click(function(e){
        e.preventDefault();
        var url=$(this).attr("href");
        $.get(url,function(data){
          $(".content .mCSB_container").append(data); //load new content inside .mCSB_container
          //scroll-to appended content 
          $(".content").mCustomScrollbar("scrollTo","h2:last");
        });
      });
      
      $(".content").delegate("a[href='top']","click",function(e){
        e.preventDefault();
        $(".content").mCustomScrollbar("scrollTo",$(this).attr("href"));
      });
      
    });
  })(jQuery);
</script>

</head>
<body>
  <section class="rt_wrap content mCustomScrollbar">
 <div class="rt_content">
     



     <section>
      <h2><strong style="color:grey;"></strong></h2>
      <div class="page_title">
       <h2 class="fl">权限展示</h2>
       <a class="fr top_rt_btn" href="roleList">返回角色列表</a>
      </div>
      <form action="powerList" method="post">
      <input type="hidden" name="_token" value="{{ csrf_token() }}">
      <input type="hidden" name="rid" value="{{ $rid }}">
      <div>
      <table>
        <ul>
        @foreach($list as $v)
        @if($v->admin_power_level==0)
          <li>
          <input type="checkbox" name="admin_pid[]" id="" @if($v->c==1)checked='checked' @endif value="{{$v->admin_pid}}">
            {{$v->admin_power_name}} :
            <ul style="margin-left:50px;">
            @foreach($list as $j)
            @if($j->admin_power_level==$v->admin_pid)
              <li style="margin:5px;"><input type="checkbox" name="admin_pid[]" id="" @if($j->c==1)checked='checked' @endif  value="{{$j->admin_pid}}" >{{$j->admin_power_name}}</li>
            @endif
            @endforeach
            <br>
            </ul>
          </li>
          <br>
        @endif
        @endforeach
        </ul>
      </table>

      <input type="submit" value="添加" class="group_btn" >
      </form>

      </div>
     </section>
     

 </div>
</section>
</body>
<script type="text/javascript">
</script>
</html>


